package cn.yitun.chat.yitunservercommonlib.converter.po2vo.user;


import cn.yitun.chat.yitunservercommonlib.dataentity.po.system.user.UserInfo;
import cn.yitun.chat.yitunservercommonlib.dataentity.vo.system.user.UserVo;
import org.mapstruct.InheritInverseConfiguration;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;

@Mapper(componentModel = "spring")
public interface UserPo2VoConverter {

    UserPo2VoConverter INSTANCE = Mappers.getMapper(UserPo2VoConverter.class);

    UserInfo vo2po(UserVo vo);

    List<UserInfo> vo2po(List<UserVo> voList);

    @InheritInverseConfiguration
    UserVo po2vo(UserInfo dto);

    @InheritInverseConfiguration
    List<UserVo> po2vo(List<UserInfo> dtoList);
}
